

use "$temp/wage_raw.dta"

* Merge wages with childcosts
merge 1:1 state_year using "$temp/childcost_raw.dta"
drop _merge

rename state stateid 

* Merge with state CPI
merge 1:1 state_year using "$temp/stateCPI.dta"
drop if _merge==2   //the CPI data has more years
drop _merge

order  stateid year icent ifcc yocent yofcc

sort stateid year
xtset stateid year, yearly


save "$temp/extendedcosts.dta", replace

clear 
